package com.sykj.cloud.member.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.sykj.cloud.member.mapper.MemberMapper;
import com.sykj.cloud.member.domain.Member;
import com.sykj.cloud.member.service.IMemberService;

/**
 * 消费者Service业务层处理
 * 
 * @author mr.will
 * @date 2021-03-09
 */
@Service
public class MemberServiceImpl implements IMemberService 
{
    @Autowired
    private MemberMapper memberMapper;

    /**
     * 查询消费者
     * 
     * @param ID 消费者ID
     * @return 消费者
     */
    @Override
    public Member selectMemberById(String ID)
    {
        return memberMapper.selectMemberById(ID);
    }

    /**
     * 查询消费者列表
     * 
     * @param member 消费者
     * @return 消费者
     */
    @Override
    public List<Member> selectMemberList(Member member)
    {
        return memberMapper.selectMemberList(member);
    }

    /**
     * 新增消费者
     * 
     * @param member 消费者
     * @return 结果
     */
    @Override
    public int insertMember(Member member)
    {
        return memberMapper.insertMember(member);
    }

    /**
     * 修改消费者
     * 
     * @param member 消费者
     * @return 结果
     */
    @Override
    public int updateMember(Member member)
    {
        return memberMapper.updateMember(member);
    }

    /**
     * 批量删除消费者
     * 
     * @param IDs 需要删除的消费者ID
     * @return 结果
     */
    @Override
    public int deleteMemberByIds(String[] IDs)
    {
        return memberMapper.deleteMemberByIds(IDs);
    }

    /**
     * 删除消费者信息
     * 
     * @param ID 消费者ID
     * @return 结果
     */
    @Override
    public int deleteMemberById(String ID)
    {
        return memberMapper.deleteMemberById(ID);
    }
}
